package ooday01;

/**
 * 说明:
 *
 * @author: luohaowei
 * @date:2023/2/21
 **/
public class Student {
    String name;
    int age;
    String calssName;
    String stuId;
    Student(){
    }
    Student(String name,int age){
        this.name=name;
        this.age=age;
    }
    Student(String name,int age,String calssName,String stuId){
        this.name=name;
        this.age=age;
        this.calssName=calssName;
        this.stuId=stuId;
    }
    void study(){
        System.out.println(this.name+"在学习");
    }
    void sayHi(){
        System.out.println("大家好,我叫"+this.name+",今年"+age+"岁了," +
                  "所在班级"+calssName+"学号为:"+stuId);
    }
    void playwith(String anotherName){
        System.out.println(this.name+"正在和"+anotherName+"一起玩");
    }
}

